package chapter030;

class Studente {
    private String name;
    private int age;

    public Studente() {
        System.out.println("实例化了一个新的Student对象。");
    }

    public Studente(String name, int age) {
        this();
        this.name = name;
        this.age = age;
    }

    public String read() {
        return "我是:" + name + ",年龄：" + age;
    }
}

public class Example11 {
    public static void main(String[] args) {
        Studente stu = new Studente("张三", 18);
        System.out.println(stu.read());
    }
}